//---------------------------------------------------------------------------
#ifndef parejaH
#define parejaH
//---------------------------------------------------------------------------
#include <iostream>

using namespace std;

template <class T1, class T2>
class TPareja {
  public:
    TPareja( ) {};
    TPareja( const T1& v1, const T2& v2 ) :
      _v1(v1), _v2(v2) {};
    const T1& v1( ) const { return _v1; };
    const T2& v2( ) const { return _v2; };
    void ponV1( const T1& v1 ) { _v1 = v1; };
    void ponV2( const T2& v2 ) { _v2 = v2; };
  private:
    T1 _v1;
    T2 _v2;
};

  template <class T1, class T2>
  ostream& operator<<( ostream& salida, const TPareja<T1,T2>& par ) {
    salida << "(" << par.v1() << ", " << par.v2() << ")";
    return salida;
  };

  template <class T1, class T2>
  ostream& operator<<( ostream& salida, const TPareja<T1,T2>* par ) {
    salida << "(" << par->v1() << ", " << par->v2() << ")";
    return salida;
  };

#endif
